import request from '@/utils/request'

/**
 * 列表遍历
 * @param {*} params
 * @returns
 */
export function viewAPI(params) {
  return request({
    url: '/parking/area/list',
    params
  })
}

/**
 * 删除
 * @param {*} id
 * @returns
 */
export function deleteAPI(id) {
  return request({
    url: `/parking/area/${id}`,
    method: 'DELETE'
  })
}

/**
 * 新增
 * @param {*} data
 * @returns
 */
export function determineAPI(data) {
  return request({
    url: '/parking/area',
    method: 'POST',
    data
  })
}

/**
 * 下拉列表
 * @returns
 */
export function dropListcarRuleAPI() {
  return request({
    url: `/parking/rule/dropList`
  })
}

/**
 * 编辑
 * @param {*} data
 * @returns
 */
export function EditRegionAPI(data) {
  return request({
    url: '/parking/area',
    method: 'PUT',
    data
  })
}
